package com.jcroke.hercules.examples;

public class Scratch {

	public static void main(String[] args) throws DatumException {
		dString r = new dString();
		dString a = new dString("310");
		dString b = new dString("08");
		dString c = new dString("250");
		dString d = new dString("12");
		
		dBoolean b0 = new dBoolean(false);
		dBoolean b1 = new dBoolean(false);
		
		if (!a.isEmpty() && !a.isNull() && !b.isEmpty() && !b.isNull()) {
			r.concat(a.toString() + "," + b.toString());
			b0.setValue(true);
		}
		if (!c.isEmpty() && !c.isNull() && !d.isEmpty() && !d.isNull()) {
			r.concat((b0.getValue() == true ? ":" : "") + c.toString() + ","
					+ d.toString());
			b1.setValue(true);
		}
		r.concat((b0.or(b1) ? ":" : "") + b0.and(b1));
		System.out.println("o: " + r.getValue());
	}

}
